3.227 \(\int \frac{(a+b \log (c (d+e x)^n))^2}{(f+g x) (h+i x)} \, dx\)

Optimal. Leaf size=264 \[ \frac{2 b n \text{PolyLog}\left (2,-\frac{g (d+e x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )}{g h-f i}-\frac{2 b n \text{PolyLog}\left (2,-\frac{i (d+e x)}{e h-d i}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )}{g h-f i}-\frac{2 b^2 n^2 \text{PolyLog}\left (3,-\frac{g (d+e x)}{e f-d g}\right )}{g h-f i}+\frac{2 b^2 n^2 \text{PolyLog}\left (3,-\frac{i (d+e x)}{e h-d i}\right )}{g h-f i}+\frac{\log \left (\frac{e (f+g x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g h-f i}-\frac{\log \left (\frac{e (h+i x)}{e h-d i}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g h-f i} \]

[Out]

((a + b*Log[c*(d + e*x)^n])^2*Log[(e*(f + g*x))/(e*f - d*g)])/(g*h - f*i) - ((a + b*Log[c*(d + e*x)^n])^2*Log[
(e*(h + i*x))/(e*h - d*i)])/(g*h - f*i) + (2*b*n*(a + b*Log[c*(d + e*x)^n])*PolyLog[2, -((g*(d + e*x))/(e*f -
d*g))])/(g*h - f*i) - (2*b*n*(a + b*Log[c*(d + e*x)^n])*PolyLog[2, -((i*(d + e*x))/(e*h - d*i))])/(g*h - f*i)
- (2*b^2*n^2*PolyLog[3, -((g*(d + e*x))/(e*f - d*g))])/(g*h - f*i) + (2*b^2*n^2*PolyLog[3, -((i*(d + e*x))/(e*
h - d*i))])/(g*h - f*i)

________________________________________________________________________________________

Rubi [A]  time = 0.370723, antiderivative size = 264, normalized size of antiderivative = 1., number of steps used = 10, number of rules used = 5, integrand size = 31, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.161, Rules used = {2418, 2396, 2433, 2374, 6589} \[ \frac{2 b n \text{PolyLog}\left (2,-\frac{g (d+e x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )}{g h-f i}-\frac{2 b n \text{PolyLog}\left (2,-\frac{i (d+e x)}{e h-d i}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )}{g h-f i}-\frac{2 b^2 n^2 \text{PolyLog}\left (3,-\frac{g (d+e x)}{e f-d g}\right )}{g h-f i}+\frac{2 b^2 n^2 \text{PolyLog}\left (3,-\frac{i (d+e x)}{e h-d i}\right )}{g h-f i}+\frac{\log \left (\frac{e (f+g x)}{e f-d g}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g h-f i}-\frac{\log \left (\frac{e (h+i x)}{e h-d i}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{g h-f i} \]

Antiderivative was successfully verified.

[In]

Int[(a + b*Log[c*(d + e*x)^n])^2/((f + g*x)*(h + i*x)),x]

[Out]

((a + b*Log[c*(d + e*x)^n])^2*Log[(e*(f + g*x))/(e*f - d*g)])/(g*h - f*i) - ((a + b*Log[c*(d + e*x)^n])^2*Log[
(e*(h + i*x))/(e*h - d*i)])/(g*h - f*i) + (2*b*n*(a + b*Log[c*(d + e*x)^n])*PolyLog[2, -((g*(d + e*x))/(e*f -
d*g))])/(g*h - f*i) - (2*b*n*(a + b*Log[c*(d + e*x)^n])*PolyLog[2, -((i*(d + e*x))/(e*h - d*i))])/(g*h - f*i)
- (2*b^2*n^2*PolyLog[3, -((g*(d + e*x))/(e*f - d*g))])/(g*h - f*i) + (2*b^2*n^2*PolyLog[3, -((i*(d + e*x))/(e*
h - d*i))])/(g*h - f*i)

Rule 2418

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*(RFx_), x_Symbol] :> With[{u = ExpandIntegrand[
(a + b*Log[c*(d + e*x)^n])^p, RFx, x]}, Int[u, x] /; SumQ[u]] /; FreeQ[{a, b, c, d, e, n}, x] && RationalFunct
ionQ[RFx, x] && IntegerQ[p]

Rule 2396

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_)/((f_.) + (g_.)*(x_)), x_Symbol] :> Simp[(Log[(e*
(f + g*x))/(e*f - d*g)]*(a + b*Log[c*(d + e*x)^n])^p)/g, x] - Dist[(b*e*n*p)/g, Int[(Log[(e*(f + g*x))/(e*f -
d*g)]*(a + b*Log[c*(d + e*x)^n])^(p - 1))/(d + e*x), x], x] /; FreeQ[{a, b, c, d, e, f, g, n, p}, x] && NeQ[e*
f - d*g, 0] && IGtQ[p, 1]

Rule 2433

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_.) + Log[(h_.)*((i_.) + (j_.)*(x_))^(m_.)]*
(g_.))*((k_.) + (l_.)*(x_))^(r_.), x_Symbol] :> Dist[1/e, Subst[Int[((k*x)/d)^r*(a + b*Log[c*x^n])^p*(f + g*Lo
g[h*((e*i - d*j)/e + (j*x)/e)^m]), x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, h, i, j, k, l, n, p, r},
 x] && EqQ[e*k - d*l, 0]

Rule 2374

Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.))/(x_), x_Symbol] :> -Sim
p[(PolyLog[2, -(d*f*x^m)]*(a + b*Log[c*x^n])^p)/m, x] + Dist[(b*n*p)/m, Int[(PolyLog[2, -(d*f*x^m)]*(a + b*Log
[c*x^n])^(p - 1))/x, x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IGtQ[p, 0] && EqQ[d*e, 1]

Rule 6589

Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[PolyLog[n + 1, c*(a
+ b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[b*d, a*e]

Rubi steps

\begin{align*} \int \frac{\left (a+b \log \left (c (d+e x)^n\right )\right )^2}{(h+227 x) (f+g x)} \, dx &=\int \left (\frac{227 \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{(227 f-g h) (h+227 x)}-\frac{g \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{(227 f-g h) (f+g x)}\right ) \, dx\\ &=\frac{227 \int \frac{\left (a+b \log \left (c (d+e x)^n\right )\right )^2}{h+227 x} \, dx}{227 f-g h}-\frac{g \int \frac{\left (a+b \log \left (c (d+e x)^n\right )\right )^2}{f+g x} \, dx}{227 f-g h}\\ &=\frac{\log \left (-\frac{e (h+227 x)}{227 d-e h}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{227 f-g h}-\frac{\left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac{e (f+g x)}{e f-d g}\right )}{227 f-g h}-\frac{(2 b e n) \int \frac{\log \left (\frac{e (h+227 x)}{-227 d+e h}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )}{d+e x} \, dx}{227 f-g h}+\frac{(2 b e n) \int \frac{\left (a+b \log \left (c (d+e x)^n\right )\right ) \log \left (\frac{e (f+g x)}{e f-d g}\right )}{d+e x} \, dx}{227 f-g h}\\ &=\frac{\log \left (-\frac{e (h+227 x)}{227 d-e h}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{227 f-g h}-\frac{\left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac{e (f+g x)}{e f-d g}\right )}{227 f-g h}-\frac{(2 b n) \operatorname{Subst}\left (\int \frac{\left (a+b \log \left (c x^n\right )\right ) \log \left (\frac{e \left (\frac{-227 d+e h}{e}+\frac{227 x}{e}\right )}{-227 d+e h}\right )}{x} \, dx,x,d+e x\right )}{227 f-g h}+\frac{(2 b n) \operatorname{Subst}\left (\int \frac{\left (a+b \log \left (c x^n\right )\right ) \log \left (\frac{e \left (\frac{e f-d g}{e}+\frac{g x}{e}\right )}{e f-d g}\right )}{x} \, dx,x,d+e x\right )}{227 f-g h}\\ &=\frac{\log \left (-\frac{e (h+227 x)}{227 d-e h}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{227 f-g h}-\frac{\left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac{e (f+g x)}{e f-d g}\right )}{227 f-g h}-\frac{2 b n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text{Li}_2\left (-\frac{g (d+e x)}{e f-d g}\right )}{227 f-g h}+\frac{2 b n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text{Li}_2\left (\frac{227 (d+e x)}{227 d-e h}\right )}{227 f-g h}+\frac{\left (2 b^2 n^2\right ) \operatorname{Subst}\left (\int \frac{\text{Li}_2\left (-\frac{g x}{e f-d g}\right )}{x} \, dx,x,d+e x\right )}{227 f-g h}-\frac{\left (2 b^2 n^2\right ) \operatorname{Subst}\left (\int \frac{\text{Li}_2\left (-\frac{227 x}{-227 d+e h}\right )}{x} \, dx,x,d+e x\right )}{227 f-g h}\\ &=\frac{\log \left (-\frac{e (h+227 x)}{227 d-e h}\right ) \left (a+b \log \left (c (d+e x)^n\right )\right )^2}{227 f-g h}-\frac{\left (a+b \log \left (c (d+e x)^n\right )\right )^2 \log \left (\frac{e (f+g x)}{e f-d g}\right )}{227 f-g h}-\frac{2 b n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text{Li}_2\left (-\frac{g (d+e x)}{e f-d g}\right )}{227 f-g h}+\frac{2 b n \left (a+b \log \left (c (d+e x)^n\right )\right ) \text{Li}_2\left (\frac{227 (d+e x)}{227 d-e h}\right )}{227 f-g h}+\frac{2 b^2 n^2 \text{Li}_3\left (-\frac{g (d+e x)}{e f-d g}\right )}{227 f-g h}-\frac{2 b^2 n^2 \text{Li}_3\left (\frac{227 (d+e x)}{227 d-e h}\right )}{227 f-g h}\\ \end{align*}

Mathematica [A]  time = 0.286641, size = 353, normalized size = 1.34 \[ \frac{2 b n \left (a+b \log \left (c (d+e x)^n\right )-b n \log (d+e x)\right ) \left (\text{PolyLog}\left (2,\frac{g (d+e x)}{d g-e f}\right )-\text{PolyLog}\left (2,\frac{i (d+e x)}{d i-e h}\right )+\log (d+e x) \left (\log \left (\frac{e (f+g x)}{e f-d g}\right )-\log \left (\frac{e (h+i x)}{e h-d i}\right )\right )\right )+b^2 n^2 \left (-2 \text{PolyLog}\left (3,\frac{g (d+e x)}{d g-e f}\right )+2 \log (d+e x) \text{PolyLog}\left (2,\frac{g (d+e x)}{d g-e f}\right )+2 \text{PolyLog}\left (3,\frac{i (d+e x)}{d i-e h}\right )-2 \log (d+e x) \text{PolyLog}\left (2,\frac{i (d+e x)}{d i-e h}\right )+\log ^2(d+e x) \log \left (\frac{e (f+g x)}{e f-d g}\right )-\log ^2(d+e x) \log \left (\frac{e (h+i x)}{e h-d i}\right )\right )+\log (f+g x) \left (a+b \log \left (c (d+e x)^n\right )-b n \log (d+e x)\right )^2-\log (h+i x) \left (a+b \log \left (c (d+e x)^n\right )-b n \log (d+e x)\right )^2}{g h-f i} \]

Antiderivative was successfully verified.

[In]

Integrate[(a + b*Log[c*(d + e*x)^n])^2/((f + g*x)*(h + i*x)),x]

[Out]

((a - b*n*Log[d + e*x] + b*Log[c*(d + e*x)^n])^2*Log[f + g*x] - (a - b*n*Log[d + e*x] + b*Log[c*(d + e*x)^n])^
2*Log[h + i*x] + 2*b*n*(a - b*n*Log[d + e*x] + b*Log[c*(d + e*x)^n])*(Log[d + e*x]*(Log[(e*(f + g*x))/(e*f - d
*g)] - Log[(e*(h + i*x))/(e*h - d*i)]) + PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)] - PolyLog[2, (i*(d + e*x))/(
-(e*h) + d*i)]) + b^2*n^2*(Log[d + e*x]^2*Log[(e*(f + g*x))/(e*f - d*g)] - Log[d + e*x]^2*Log[(e*(h + i*x))/(e
*h - d*i)] + 2*Log[d + e*x]*PolyLog[2, (g*(d + e*x))/(-(e*f) + d*g)] - 2*Log[d + e*x]*PolyLog[2, (i*(d + e*x))
/(-(e*h) + d*i)] - 2*PolyLog[3, (g*(d + e*x))/(-(e*f) + d*g)] + 2*PolyLog[3, (i*(d + e*x))/(-(e*h) + d*i)]))/(
g*h - f*i)

________________________________________________________________________________________

Maple [C]  time = 0.912, size = 4712, normalized size = 17.9 \begin{align*} \text{output too large to display} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((a+b*ln(c*(e*x+d)^n))^2/(g*x+f)/(i*x+h),x)

[Out]

1/(f*i-g*h)*ln(i*x+h)*ln(c)^2*b^2-1/(f*i-g*h)*ln(g*x+f)*ln(c)^2*b^2-I*n/(f*i-g*h)*ln(i*x+h)*ln(((i*x+h)*e+d*i-
e*h)/(d*i-e*h))*b^2*Pi*csgn(I*c)*csgn(I*c*(e*x+d)^n)^2+I*n/(f*i-g*h)*dilog(((i*x+h)*e+d*i-e*h)/(d*i-e*h))*b^2*
Pi*csgn(I*c)*csgn(I*(e*x+d)^n)*csgn(I*c*(e*x+d)^n)+I*n/(f*i-g*h)*ln(g*x+f)*ln(((g*x+f)*e+d*g-f*e)/(d*g-e*f))*b
^2*Pi*csgn(I*c)*csgn(I*c*(e*x+d)^n)^2+b^2/(f*i-g*h)*ln((e*x+d)*i-d*i+e*h)*ln(e*x+d)^2*n^2+I/(f*i-g*h)*ln(g*x+f
)*ln(c)*Pi*b^2*csgn(I*c)*csgn(I*(e*x+d)^n)*csgn(I*c*(e*x+d)^n)+I/(f*i-g*h)*ln(g*x+f)*Pi*a*b*csgn(I*c)*csgn(I*(
e*x+d)^n)*csgn(I*c*(e*x+d)^n)+I*ln((e*x+d)^n)/(f*i-g*h)*ln(g*x+f)*b^2*Pi*csgn(I*c)*csgn(I*(e*x+d)^n)*csgn(I*c*
(e*x+d)^n)-I*n/(f*i-g*h)*dilog(((g*x+f)*e+d*g-f*e)/(d*g-e*f))*b^2*Pi*csgn(I*c)*csgn(I*(e*x+d)^n)*csgn(I*c*(e*x
+d)^n)-I/(f*i-g*h)*ln(i*x+h)*Pi*a*b*csg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(e*x
+d)^n)^5-1/4/(f*i-g*h)*ln(i*x+h)*Pi^2*b^2*csgn(I*c)^2*csgn(I*c*(e*x+d)^n)^4+1/2/(f*i-g*h)*ln(i*x+h)*Pi^2*b^2*c
sgn(I*c)*csgn(I*c*(e*x+d)^n)^5-2*b^2*n/(f*i-g*h)*ln(e*x+d)*ln((g*(e*x+d)-d*g+f*e)/(-d*g+e*f))*ln((e*x+d)^n)-2*
b^2/(f*i-g*h)*ln((e*x+d)*i-d*i+e*h)*ln(e*x+d)*ln((e*x+d)^n)*n+2*b^2/(f*i-g*h)*ln(g*(e*x+d)-d*g+f*e)*ln(e*x+d)*
ln((e*x+d)^n)*n+1/2/(f*i-g*h)*ln(i*x+h)*Pi^2*b^2*csgn(I*c)*csgn(I*(e*x+d)^n)^2*csgn(I*c*(e*x+d)^n)^3-1/4/(f*i-
g*h)*ln(i*x+h)*Pi^2*b^2*csgn(I*(e*x+d)^n)^2*csgn(I*c*(e*x+d)^n)^4+1/2/(f*i-g*h)*ln(i*x+h)*Pi^2*b^2*csgn(I*(e*x
+d)^n)*csgn(I*c*(e*x+d)^n)^5+1/4/(f*i-g*h)*ln(g*x+f)*Pi^2*b^2*csgn(I*c)^2*csgn(I*c*(e*x+d)^n)^4

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} a^{2}{\left (\frac{\log \left (g x + f\right )}{g h - f i} - \frac{\log \left (i x + h\right )}{g h - f i}\right )} + \int \frac{b^{2} \log \left ({\left (e x + d\right )}^{n}\right )^{2} + b^{2} \log \left (c\right )^{2} + 2 \, a b \log \left (c\right ) + 2 \,{\left (b^{2} \log \left (c\right ) + a b\right )} \log \left ({\left (e x + d\right )}^{n}\right )}{g i x^{2} + f h +{\left (g h + f i\right )} x}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))^2/(g*x+f)/(i*x+h),x, algorithm="maxima")

[Out]

a^2*(log(g*x + f)/(g*h - f*i) - log(i*x + h)/(g*h - f*i)) + integrate((b^2*log((e*x + d)^n)^2 + b^2*log(c)^2 +
 2*a*b*log(c) + 2*(b^2*log(c) + a*b)*log((e*x + d)^n))/(g*i*x^2 + f*h + (g*h + f*i)*x), x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{b^{2} \log \left ({\left (e x + d\right )}^{n} c\right )^{2} + 2 \, a b \log \left ({\left (e x + d\right )}^{n} c\right ) + a^{2}}{g i x^{2} + f h +{\left (g h + f i\right )} x}, x\right ) \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))^2/(g*x+f)/(i*x+h),x, algorithm="fricas")

[Out]

integral((b^2*log((e*x + d)^n*c)^2 + 2*a*b*log((e*x + d)^n*c) + a^2)/(g*i*x^2 + f*h + (g*h + f*i)*x), x)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*ln(c*(e*x+d)**n))**2/(g*x+f)/(i*x+h),x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (b \log \left ({\left (e x + d\right )}^{n} c\right ) + a\right )}^{2}}{{\left (g x + f\right )}{\left (i x + h\right )}}\,{d x} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((a+b*log(c*(e*x+d)^n))^2/(g*x+f)/(i*x+h),x, algorithm="giac")

[Out]

integrate((b*log((e*x + d)^n*c) + a)^2/((g*x + f)*(i*x + h)), x)